programming4us
           
 
 
Windows

SOA with .NET and Windows Azure : Windows Workflow Foundation (part 4) - Activities

- Free product key for windows 10
- Free Product Key for Microsoft office 365
- Malwarebytes Premium 3.7.1 Serial Keys (LifeTime) 2019
12/19/2010 4:35:02 PM

Activities

A workflow is a sequence of activities executed by the workflow engine. An activity should be modeled as a real-world action required for completing a parent business process. An activity is a class that encapsulates logic and can potentially be reused across different workflows.

WF includes several activities known as the base activity library. Activities from the base activity library are commonly used with sequential workflows (Table 2).

Table 2. Base library activities commonly used with sequential workflows.
ActivityDescription 
IfElseallows conditions to be specified in the workflow and the runtime engine evaluates each condition and acts upon it based on the result (the IfElse activity can contain other IfElse activities and a default IfElse activity if no other condition is met)Looping and Synchronization
Whileaccepts a condition and evaluates it at the beginning of every iteration (if the condition is true, the child activity is run repeatedly until the condition becomes false)
Replicatorexecutes a child activity a given number of times (similar to the foreach statement in C#)
Sequenceis used to execute a group of activities, one at a time, in a predefined order
Parallelexecutes two or more sequences of activities in parallel or in an interleaved manner (all sequence activities must be completed before the workflow moves to the next activity)
Listenis used to idle the workflow process and wait for a wake-up call (the Listen activity is typically used when human interaction is required—it serializes the workflow and goes into a passive mode when it is waiting for human intervention and upon receiving an event, it reactivates the workflow and continues with the processing logic)Human Intervention
EventDrivenis implemented by using the EventDriven activity (a ListenEventDriven activities and child activities that represent human events) activity must contain
HandleExternalEventis invoked when an event specified in an interface is raised (the HandleExternalEvent activity is used by WF to communicate with an external service)
Delayis used to suspend the execution of the workflow for a specified amount of time
Codeallows source code to be injected directly into the workflow (it fires the ExecuteCode event that executes the code, plus this activity can call an external assembly)Execution
CallExternalMethodis used to call a method in a class available to the workflow (the interface and its implementation must be available in the same assembly)
InvokeWorkflowinvokes another workflow to start executing
InvokeWebServiceinvokes a Web service external to the workflow application (creates a Web reference to a Web service and allows operations on the service to be invoked)
WebServiceInputenables a workflow to receive a Web service request
WebServiceOutputpairs with a WebServiceInput activity to respond to a service request (to use this activity, the WebServiceInput activity must be configured first)
TransactionScopeis used to represent System.Transactions in WF (supports all the properties currently supported by System.Transactions)
Terminateis used to terminate the execution of the workflow

State machine workflows provide a way of defining workflows that match an organization’s business process by using states, events, and transitions to model workflow logic. A state represents a snapshot of the business process. The workflow is always in one state and will transition to a new state when it receives an event. Typically, some action will take place in the outside world for the state in the workflow to be transitioned to a new state. On reaching the final state, the workflow is completed.

The base activity library includes several activities designed to enable state machine workflows (Table 3).

Table 3. Base library activities commonly used with state machine workflows.
ActivityDescription
Staterepresents a state in a state machine workflow (when an event arrives, the workflow will transition from one state activity to a new state activity)
EventDrivenrepresents an event handler in a state machine and is placed inside a state activity
SetStateis used to model transitions in a state machine workflow (includes the TargetStateName property that points to the destination state)
StateInitializationStateFinalization used to perform pre- and post-processing in a state and run when the state machine transitions into the state containing the initialization activity (the StateFinalization activity runs when the state machine transitions out of a state)

A state machine workflow is commonly consumed by one or more UI components that must reflect the current state of the workflow and allow users to only perform legal events. WF includes the StateMachineWorkflowInstance class that provides an API to manage and query a state machine workflow. The class includes properties used to fetch the current state name and find legal transitions for the state. It also includes properties that provide a history of all the states the workflow has been through.

Other -----------------
- Windows 7 : Creating and Enforcing Bulletproof Passwords (part 3) - Recovering from a Forgotten Password
- Windows 7 : Creating and Enforcing Bulletproof Passwords (part 2) - Taking Advantage of Windows 7’s Password Policies
- Windows 7 : Creating and Enforcing Bulletproof Passwords (part 1)
- Windows 7 : Understanding User Account Control (part 3) - User Account Control Policies
- Windows 7 : Understanding User Account Control (part 2) - Configuring User Account Control
- Windows 7 : Understanding User Account Control (part 1) - Elevating Privileges
- Windows 7 : Encrypting a Disk with BitLocker (part 2) - Enabling BitLocker on a System Without a TPM
- Windows 7 : Encrypting a Disk with BitLocker (part 1) - Enabling BitLocker on a System with a TPM
- Windows 7 : Securing the File System - Encrypting Files and Folders
- SOA with .NET and Windows Azure : Service Consumers with WCF
- Windows 7 : Setting Security Permissions on Files and Folders (part 5) - Assigning Special Permissions
- Windows 7 : Setting Security Permissions on Files and Folders (part 4) - Assigning Standard Permissions
- Windows 7 : Setting Security Permissions on Files and Folders (part 3) - Assigning a User to Multiple Security Groups
- Windows 7 : Setting Security Permissions on Files and Folders (part 2) - Assigning a User to a Security Group
- Windows 7 : Setting Security Permissions on Files and Folders (part 1) -
- Cloud-Enabling the ESB with Windows Azure (part 2) - Sending Messages to Azure’s AppFabric Service Bus
- Cloud-Enabling the ESB with Windows Azure (part 1) - Receiving Messages from Azure’s AppFabric Service Bus
- Windows 7 : Sending and Receiving Secure Email (part 2) - Obtaining Another Person’s Public Key
- Windows 7 : Sending and Receiving Secure Email (part 1) - Setting Up an Email Account with a Digital ID
- Windows 7 : Maintaining Your Privacy While Reading Email
 
 
 
Top 10
 
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Finding containers and lists in Visio (part 2) - Wireframes,Legends
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Finding containers and lists in Visio (part 1) - Swimlanes
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Formatting and sizing lists
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Adding shapes to lists
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Sizing containers
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 3) - The Other Properties of a Control
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 2) - The Data Properties of a Control
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 1) - The Format Properties of a Control
- Microsoft Access 2010 : Form Properties and Why Should You Use Them - Working with the Properties Window
- Microsoft Visio 2013 : Using the Organization Chart Wizard with new data
- First look: Apple Watch

- 3 Tips for Maintaining Your Cell Phone Battery (part 1)

- 3 Tips for Maintaining Your Cell Phone Battery (part 2)
programming4us programming4us